package com.ciei.dpagm.common.enums;

import com.baomidou.mybatisplus.annotation.EnumValue;
import com.ciei.dpagm.util.EnumUtil;

/**
 * @author yw
 * @date 2023/7/25
 **/
public enum AccessEntranceEnum {

    /**
     * wpf客户端
     */
    WPF("42fec5bb39a12715eb2038ef2d024f7d","wpf"),

    /**
     * web管理后台
     */
    WEB("2567a5ec9705eb7ac2c984033e06189d","web");

    /**
     * 入口描述
     */
    @EnumValue
    private String accessEntranceToken;
    private String description;

    public static AccessEntranceEnum entranceValueOf(String accessEntranceToken) {
        return EnumUtil.getEnumObject(AccessEntranceEnum.class, e -> e.getAccessEntranceToken().equals(accessEntranceToken)).orElse(null);
    }

    AccessEntranceEnum(String accessEntranceToken,String description) {
        this.accessEntranceToken = accessEntranceToken;
        this.description = description;
    }

    public String getAccessEntranceToken(){
        return accessEntranceToken;
    }

    public String getDescription() {
        return description;
    }
}
